<?php
// +----------------------------------------------------------------------
// | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2019 http://www.thinkcmf.com All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: 小夏 < 449134904@qq.com>
// +----------------------------------------------------------------------
namespace app\portal\validate;

use think\Validate;

class AdminArticleValidate extends Validate
{
    protected $rule = [
        'post_title'   => 'require',
        'categories'   => 'require',
        'post_content' => 'require',
        // 'thumbnail'    => 'require',
    ];
    protected $message = [
        'post_title.require'   => '请输入作品标题!',
        'categories.require'   => '请选择作品分类!',
        'post_content.require' => '请输入作品描述',
        // 'thumbnail.require'    => '请选择作品封面!',
    ];

    protected $scene = [
//        'add'  => ['user_login,user_pass,user_email'],
        //        'edit' => ['user_login,user_email'],
    ];
}
